<template>
  <div class="homeListOne">
    <img src="@/assets/img/hg.png" alt="" />
    <h2>
      这里将会根据您的体质和当前节气，为您推荐适合您的饮食参考内容。早饭要吃好，午餐要吃饱，晚饭要吃少，细中有粗、荤素搭配,营养均衡。
    </h2>
    <HomeDetailList
      v-for="(v, i) in arrone"
      :key="i"
      :title="v.title"
      :imgurl="v.imgurl"
      :text="v.text"
    />
  </div>
</template>

<script>
import getlink from "../api/getlink.js";
import HomeDetailList from "@/components/homeDetailList.vue";
export default {
  data() {
    return {
      arrone:[],
    };
  },
  components: {
    HomeDetailList,
  },
  created() {
    getlink("/data/list/xiaoming").then((ok) => {
      // this.arr=ok.data.rightmeals

      this.arrone = ok.data.rightmeals.filter((item) => {
        return item.date == "1";
      });
    });
  },
};
</script>

<style scoped>
img {
  height: 1.5rem;
  width: 100%;
}
h2 {
  height: 0.9rem;
  padding: 0.2rem 0.2rem 0 0.2rem;
}
</style>